home *** CD-ROM | disk | FTP | other *** search
/ Mac Magazin/MacEasy 51 / Mac Magazin and MacEasy Magazine CD - Issue 51.iso / Software / Mobiles Büro / Sonstiges / Melody Pilot ƒ / Speeding up Music Box < prev   
Text File  |  1998-07-29  |  2KB  |  31 lines

  1. Speeding up Tan Kok Mun's Music Box (PalmPilot cbasPad program):
  2.  
  3. In Version 2.01 of Music Box there are two things that can be improved: 
  4.  
  5. 1) You need to type in the entire title of the song.  This is tedious and causes you to name the songs with abbreviations instead of the full song titles.
  6.  
  7. 2) It takes a while for Music Box to search through all of the memo records for the matching song title.  This is especially slow if you have a lot of memo records and the one you are looking for is near the end alphabetically.
  8.  
  9. In the cbasPad editor, bring up the Music Box source and replace lines 20 to 26:
  10.  
  11. 20 z=z+1
  12. 22 if (op "db", 1145132097, 1835363695,z)=0 then 5000 24 x=fn 80:gosub 3000
  13. 26 if not(a$=s$) then 20
  14.  
  15. with:
  16.  
  17. 20 z=op "mfind",s$,n
  18. 21 if z=-1 then 5000
  19. 22 if (op "db", 1145132097, 1835363695,z)=0 then 5000 24 x=fn 80:gosub 3000
  20.  
  21. (Yes, line 22 is actually unchanged.  What this does is replace a slow BASIC loop with a quick mfind call to find the song title.).
  22.  
  23. This allows you to enter just the starting substring of a song to play it.  You can now play a song titled "Happy Birthday" by just typing in "Hap" (of even "Ha" or "H" if there are no other matches or that would match first).  If there is a "london bridge" and a "looney", entering "lo" would play "london bridge" while "loo" would play "looney". 
  24.  
  25. I have sent this enhancement to Tan Kok Mun, but he has not released a new version of Music Box with it yet.
  26.  
  27. Music Box: http://home.pacific.net.sg/~kokmun
  28. cbasPad: http://www.nicholson.com/rhn/pilot.html
  29.  
  30.         Have fun!
  31.         Robert Jen (http://www.rjen.com or mailto:rjen@rjen.com)